var num = 10;   //打印字符数
var char = "A";
/**
打印偶数字符倒三角型
*/
function for3(){
  while(num>0){
    var str = "";
    for(var i = 0;i<num;i++){
      if(num%2==0){//判断打印字符是否为偶数，为偶数则进行打印
        str = str + char;
      }else{//打印字符数为奇数则不打印
        continue;
      }

    }
    console.log(str);
    num--;
  }
}

for3();
